<?php
/**
 * Created by PhpStorm.
 * User: 郝飞
 * Date: 2017/5/10
 * Time: 17:06
 */
namespace Tools\Controller;

use Common\Controller\FrontbaseController;

class SlideController extends FrontbaseController{
	//获取幻灯
	function index(){
		$idname = I('identification');
		$home_slides=sp_getslide($idname);
		foreach($home_slides as $key => $value){
			$home_slides[$key]['slide_pic'] = sp_get_asset_upload_path($home_slides[$key]['slide_pic']);
		}
		if ($home_slides) {
			$arr['status'] = '1';
			$arr['msg'] = '查找幻灯成功';
			$arr['slideInfo'] = $home_slides;
			$this->output($arr);
		} else {
			$arr['status'] = '0';
			$arr['msg'] = '查找幻灯失败';
			$this->output($arr);
		}
	}
}